﻿using System;
using System.Collections.Generic;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace KXmlUIControl
{
    public class XmlGroupMemberObject
    {
        public string Name { get; set; }
 
        public string Location { get; set; }

        public int Level { get; set; }

        public XmlGroupMemberObject()
        {
            Level = 0;
        }

        public void SetControlValue(Control control)
        {
            SetLocation(control);
        }
      
        public void SetLocation(Control ctl)
        {
            if (string.IsNullOrEmpty(Location))
            {
                return;
            }
            Point value = StaticTypes.GetLocation(Location);
            if (value != Point.Empty)
            {
                ctl.Location = value;
            }
        }

    }
}
